Skip to content

Conversation

@Ravencentric
Copy link
Contributor

Fixes: #14865

@Ravencentric Ravencentric changed the title make FILE_ATTRIBUTE__* available on all platforms make FILE_ATTRIBUTE_* available on all platforms Oct 11, 2025
@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

Copy link
Collaborator

@hauntsaninja hauntsaninja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! (CI failure looks unrelated)

@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

@Ravencentric
Copy link
Contributor Author

Ravencentric commented Oct 12, 2025

I'm not sure how to make pyright happy here. Fixing windows breaks Linux and vice versa.

  • On windows, I need # pyright: ignore to suppress the redefinition warning
  • On non-windows, the same # pyright: ignore comments become unnecessary

@Ravencentric
Copy link
Contributor Author

Should I import every symbol explicitly like socket.pyi does?

Copy link
Collaborator

@hauntsaninja hauntsaninja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh hmm. Maybe I led you astray then and your original version was fine. Sorry about that! (For what it's worth, importing every symbol isn't as bad as it sounds, since stubtest will tell us if things go out of sync)

@Ravencentric
Copy link
Contributor Author

In that case, I'll import the symbols explicitly because I wasn't much of a fan of the weird if sys.platform != "win32": check either.

@github-actions

This comment has been minimized.

@Ravencentric
Copy link
Contributor Author

@hauntsaninja This is ready for review 🎉

@Ravencentric Ravencentric changed the title make FILE_ATTRIBUTE_* available on all platforms make stat.FILE_ATTRIBUTE_* available on all platforms Oct 13, 2025
@Ravencentric
Copy link
Contributor Author

Gentle bump

@github-actions
Copy link
Contributor

github-actions bot commented Nov 8, 2025

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

Copy link
Collaborator

@srittau srittau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@srittau srittau merged commit 5aea297 into python:main Nov 8, 2025
63 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reconsider platform availability of stat.FILE_ATTRIBUTE_*

3 participants